﻿using EasyNet.Componets.Core.Events;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace EasyNet.Componets.Core.Domain.Events
{
    public interface IDomainEventHandler<in TDomainEvent> : IEventHandler<TDomainEvent>
       where TDomainEvent : IDomainEvent
    {
        void Handle<TDomainEventResult>(TDomainEvent domainEvent, Action<TDomainEventResult> callback) where TDomainEventResult : IDomainEventResult;

        new void Handle(TDomainEvent domainEvent);
    }
}
